home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / batchut / batkit50.zip / BATKIT.DOC < prev    next >
Text File  |  1988-08-23  |  33KB  |  700 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.                                       BatKit
  12.  
  13.                                    Utilities for
  14.                                Menus in Batch Files
  15.  
  16.                                         by
  17.  
  18.                                     Ken Hipple
  19.                                    [74076,2331]
  20.                                 All Right Reserved
  21.  
  22.                       [Including: GetKey, SaveDir, and Wait]
  23.  
  24.  
  25.                                  Copyright 1988 by
  26.                      Mississippi Data Equipment Company, Inc.
  27.                              625C Lakeland East Drive
  28.                                 Jackson, MS   39208
  29.                                   (601) 932-6332
  30.  
  31.  
  32.  
  33.      BatKit   ver. 5.0                7/15/88                         Page: 2
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.                          T A B L E   O F   C O N T E N T S
  42.  
  43.  
  44.      GETKEY  . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .    3
  45.        OVERVIEW  . . . . . . . . . . . . . . . . . . . . . . . . . . . .    3
  46.        USING GETKEY  . . . . . . . . . . . . . . . . . . . . . . . . . .    4
  47.           Usage
  48.           Response Editing
  49.        COMMAND LINE PARAMETERS . . . . . . . . . . . . . . . . . . . . .    5
  50.        DISPLAYING TEXT . . . . . . . . . . . . . . . . . . . . . . . . .    8
  51.           # control character
  52.           @ control character
  53.  
  54.      GETKEY 4.x AND GETSTRNG COMPATIBILITY . . . . . . . . . . . . . . .   11
  55.  
  56.      WAIT  . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   12
  57.  
  58.      SAVEDIR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   13
  59.  
  60.      USING THE DOS ENVIRONMENT . . . . . . . . . . . . . . . . . . . . .   14
  61.  
  62.      REGISTERING BatKit  . . . . . . . . . . . . . . . . . . . . . . . .   15
  63.  
  64.  
  65.  
  66.      BatKit   ver. 5.0                7/15/88                         Page: 3
  67.  
  68.  
  69.  
  70.      GETKEY OVERVIEW:
  71.  
  72.        GetKey is a utility program designed to be used in a batch file.  Its
  73.      main function is to make batch files interactive by allowing the user to
  74.      enter a response to a prompt or question.  Used with an appropriate text
  75.      file and batch file it can be the basis of a menu system.  Other uses
  76.      include displaying text files and messages, playing tones, clearing
  77.      screens larger than 80x25, and providing a 'hidden' escape method from a
  78.      batch file.
  79.  
  80.        GetKey enables you to use a single batch (BAT) file and a single text
  81.      file to completely control the operation of a system from startup to
  82.      shutdown.
  83.  
  84.        GetKey has been tested with DOS versions from 2.1 to 3.3.  It will run
  85.      on most IBM PCs and compatibles.  Features of GetKey include:
  86.  
  87.       - Returns an ERRORLEVEL for all    - Option to wait for RETURN key
  88.         keys including function keys       before accepting a response
  89.  
  90.       - Option to insert response        - Can wait a given time for a
  91.         into the environment               response and then continue
  92.  
  93.       - Fast text display & screen       - Can display a file, message or
  94.         handling                           both
  95.  
  96.       - Optional response echoing        - Can display a section of a file
  97.  
  98.       - Optional bad response message    - Flexible color handling 
  99.  
  100.       - Option to delete bad responses   - Time and date display options
  101.       
  102.       - Optional beep on bad response    - Does display delays and pauses
  103.       
  104.       - Built-in help screens            - 'Smart' clear screen function
  105.  
  106.       - Clear type-ahead buffer option   - Limited screen mode switching 
  107.  
  108.       - Tone generation capabilities     - Optional response validation
  109.  
  110.       - Adjustable max. response length  - Can trim spaces from response
  111.  
  112.       - Option to force uppercase        - Defaults can be modified
  113.  
  114.  
  115.  
  116.      BatKit   ver. 5.0                7/15/88                         Page: 4
  117.  
  118.  
  119.      USING GETKEY:
  120.  
  121.         When GetKey is run it first displays any file or message specified,
  122.      then waits for the user to enter a response.  You can specify the
  123.      maximum length allowed.  After the response is entered it is validated
  124.      if necessary.  The ASCII value of the first letter of the response is
  125.      then returned to the batch file in ERRORLEVEL.  The response can also be
  126.      placed into the environment if you want.  The values returned by func-
  127.      tion keys are their extended ASCII value plus 128.  These values are: 
  128.  
  129.                          F1-F10    SHIFT F1-F10   CTRL F1-F10   ALT F1-F10
  130.      Value Returned:     187-196     212-221        222-231      232-241
  131.  
  132.      Usage:
  133.        GetKey  [?] [/A] [/B] [/C] [/D] [/E] [/F"filename[@s]"] [/G["char"]]
  134.                [/H] [/I] [/K"chars" | /KF"filename[@s]"] [/Lnnn] [/M"msg"]
  135.                [/N["char"]] [/O] [/P] [/R] [/S] [/T] [/U] [/V["var"]]
  136.                [/Wnnnn] [/X] [/Z]
  137.  
  138.      Items in [] are optional.  The character | means or (for example, you
  139.      can use /K or /KF but not both together).  Most parameters can have a +
  140.      or - appended to them (ex. /B- or /G+"*").  See below for which para-
  141.      meters can use this.  Note that any place GetKey expects a number you
  142.      may enter it in decimal or hexadecimal.  To use hexadecimal add a & in
  143.      front of the number.  For example, to GetKey &A0 is the same as 160.
  144.      Arguments enclosed in quotes (") above MUST be enclosed in quotes on
  145.      the command line.
  146.  
  147.      Response Editing:
  148.  
  149.      The following keys can be used during response entry for editing:
  150.  
  151.      Home -         Returns the cursor to the first character of the
  152.                     response.
  153.  
  154.      End -          Moves the cursor to the right end of the response.
  155.  
  156.      Left Arrow -   Moves the cursor one space to the left.
  157.  
  158.      Right Arrow -  Moves the cursor one space to the right.
  159.  
  160.      Ins -          Toggles Insert/Overstrike mode.  Insert mode is indicated
  161.                     by a large cursor.
  162.  
  163.      Del -          Deletes the character under the cursor.
  164.  
  165.      BackSpace -    Deletes the character to the left of the cursor.
  166.  
  167.      Esc -          Deletes the entire response.
  168.  
  169.  
  170.  
  171.      BatKit   ver. 5.0                7/15/88                         Page: 5
  172.  
  173.  
  174.  
  175.      COMMAND LINE PARAMETERS for GetKey: (The value in [] after some defini-
  176.      tions is the "initial" default for that parameter.  That is, the action
  177.      for that parameter if the switch is not included in the command line. 
  178.      If the default is [off], the switch would change it to ON.  Most of
  179.      these initial defaults can be changed by using the /O switch to patch
  180.      GETKEY.EXE.  Toggles can also be forced ON or OFF using + or -.)
  181.  
  182.      /A  - Makes the RETURN key be one of the Acceptable responses for GetKey
  183.            (see /K and /KF).  If not used with the /K|/KF parameter it makes
  184.            the RETURN key be the only acceptable response. [off]
  185.  
  186.      /B  - Toggles the setting for the error Beep produced by an invalid
  187.            response to GetKey (see /K|/KF) and Ctrl-G beeps. [on]
  188.  
  189.      /C  - Toggles the Clear screen setting.  If no color setting has been
  190.            done the original screen colors or attributes are used; otherwise
  191.            the last color that was set is used.  GetKey determines the
  192.            original screen colors by looking at the attributes at the cursor
  193.            position that was current when GetKey was called.  This means that
  194.            the color the cursor is when you invoke GetKey is the color it
  195.            thinks the screen is. [off]
  196.  
  197.      /D  - Toggles the 'Delete (erase) unacceptable response' setting  (see
  198.            /K|/KF). [off]
  199.  
  200.      /E  - Toggles the setting for displaying an Error message when the user
  201.            enters an unacceptable response (see /K|/KF). [off]
  202.  
  203.      /F  - Causes GetKey to display the File "filename".  Using the syntax
  204.            "filename@s" causes GetKey to display only section s of the file. 
  205.            See 'Displaying Text' below for more information.
  206.  
  207.      /G  - Toggles the setting for a Guide line.  When ON, it displays a
  208.            guide line showing the length of the maximum acceptable response. 
  209.